package org.grow.preview.controller;

import org.grow.preview.domain.Group;
import org.grow.preview.infrastructure.JpaGroup;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
public class GroupController {

    @Resource
    private JpaGroup jpaGroup;

    @PutMapping("/group")
    public Group save(@RequestBody Group group){
        return jpaGroup.save(group);
    }
}
